package com.youbo.cloudmall.search.vo;

import com.youbo.common.to.es.SkuEsModel;
import lombok.Data;

import java.util.List;

/**
 * @author youbo
 * @version 1.0
 * @date 2021/10/14 11:45
 */
@Data
public class SearchResult {
    //查询到的所有商品信息
    private List<SkuEsModel> products;
    private Integer pageNum;//当前页面
    private Long total;//总记录数
    private Integer totalPages;//总页数

    private List<BrandVo> brands;//当前查询到的结果所有涉及到的品牌

    private List<AttrVo> attrs;//查询到的所有属性
    private List<CatalogVo> catalogs;//查询到的所有分类


    @Data
    public static class BrandVo{
        private Integer brandId;
        private Integer brandName;
        private Integer brandImg;
    }

    @Data
    public static class CatalogVo{
        private Integer catalogId;
        private String catalogName;

    }

    @Data
    public static class AttrVo{
        private Long attrId;
        private String attrName;
        private List<String> attrValue;
    }
}
